#ifndef BPE_BOX_3D
#define BPE_BOX_3D



#include <irrlicht.h>	//needed for the planes
using namespace irr;
using namespace core;

#include <stack>
using namespace std;
#include <boost/shared_array.hpp>
using namespace boost;

#include "../BPEMath/BPEVector3d.h"
#include "../BPEMath/BPEPoint3d.h"

class BPEBox3d{


private:
	shared_array<BPEVector3d> vertices;
	
	BPEPoint3d center;
	BPEVector3d rotation;

public:
	BPEBox3d();
	BPEBox3d(const BPEPoint3d &center);
	BPEBox3d(const BPEPoint3d &center, const shared_array<BPEPoint3d> &vertices);

	void setRotation(BPEVector3d rotation);
	shared_array<BPEVector3d> getVertices();
	BPEPoint3d getCenter();
	void setCenter(const BPEPoint3d &c);

	shared_array<plane3d<f32>> getPlanes(); 


	bool collide(BPEBox3d *other,BPEVector3d &normal, double &depth);
};

#endif